<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

/**
 * App\Models\ConfigWithdraw
 *
 * @property int $id
 * @property bool $is_open
 * @property array|null $allowed_methods all available methods of withdraw
 * @property array|null $allowed_weekdays when users are allowed to withdraw
 * @property string $allowed_lowest_amount at least has this amount in user account before withdraw
 * @property string $allowed_highest_amount the highest money which user can withdraw each time
 * @property int $multiple the money withdrawed must follow this integer multiple
 * @property string $charge_type deduct service charge from the amount of withdraw money or of user total money
 * @property int $charge_percent how much service charge pay to this platform
 * @property string $allowed_lowest_charge if the money withdrawing less than amount this then deduct this amount
 * @property string $allowed_highest_charge if the money withdrawing greater than this amount then deduct this amount
 * @property int $frequency how much times user allows withdrawing each day
 * @property string|null $description remark
 * @method static \Database\Factories\ConfigWithdrawFactory factory(...$parameters)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw newModelQuery()
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw newQuery()
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw query()
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereAllowedHighestAmount($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereAllowedHighestCharge($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereAllowedLowestAmount($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereAllowedLowestCharge($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereAllowedMethods($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereAllowedWeekdays($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereChargePercent($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereChargeType($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereDescription($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereFrequency($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereId($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereIsOpen($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereMultiple($value)
 * @mixin \Eloquent
 * @property string $allowed_channel local, freelance
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereAllowedChannel($value)
 * @property int $is_local
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereIsLocal($value)
 * @property string $sandpay_quota
 * @property string|null $withdraw_end_time
 * @property string|null $withdraw_start_time
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereSandpayQuota($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereWithdrawEndTime($value)
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereWithdrawStartTime($value)
 * @property int $xzb_charge_percent
 * @method static \Illuminate\Database\Eloquent\Builder|ConfigWithdraw whereXzbChargePercent($value)
 */
class ConfigWithdraw extends Model
{
    use HasFactory;
	
	protected $guarded = ['id'];
	
	public $timestamps = false;
	
	protected $casts = [
		'is_open' => 'boolean',
		'allowed_methods' => 'json',
		'allowed_weekdays' => 'json',
	];
}
